<% form_for(@task) do |f| %>
  <%= f.error_messages %>

  <p>
    <%= f.label :title %><br />
    <%= f.text_field :title %>
  </p>
  <p>
    <%= f.label :description %><br />
    <%= f.text_area :description %>
  </p>
  <p>
    <%= f.label :goal_id %><br />
    <%= f.collection_select :goal_id,@goals,:id,:title %>
  </p>
	



  <p>
    <%= f.submit 'Save' %>
  </p>
<% end %>